﻿using Ongoal.Quotation.Common;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Ongoal.Quotation.Service.Model.Sys
{
    /// <summary>
    /// 可视化字段表
    /// </summary>
    public class T_Sys_Interfacesettings : ModelBase
    {
        /// <summary>
        /// 字段ID
        /// </summary>
        public int FieldID { get; set; }

        /// <summary>
        /// 表ID
        /// </summary>
        public int TableID { get; set; }

        /// <summary>
        /// 排序
        /// </summary>
        public int? Seq { get; set; }

        /// <summary>
        /// 字段名
        /// </summary>
        public string FieldName { get; set; }
        /// <summary>
        /// 显示名称
        /// </summary>
        public string Showlabel { get; set; }
        /// <summary>
        /// 显示宽度
        /// </summary>
        public int Showwidth { get; set; }
        /// <summary>
        /// 正则验证
        /// </summary>
        public string RegxValid { get; set; }
        /// <summary>
        /// 表单类型
        /// </summary>
        public int FormType { get; set; }
        /// <summary>
        /// 是否在表格中显示
        /// </summary>
        public bool IsshowInTalbe { get; set; } = true;
        /// <summary>
        /// 是否可编辑
        /// </summary>
        public bool IsFormEdit { get; set; } = true;

        /// <summary>
        /// 是否可以为空
        /// </summary>
        public bool Isrequired { get; set; } = false;
        /// <summary>
        /// 数据源类型
        /// </summary>
        public int SoursedataType { get; set; }
        /// <summary>
        /// 数据源编码
        /// </summary>
        public string SoursedataCode { get; set; }
        /// <summary>
        /// 界面化ID
        /// </summary>
        public int InterfaceTableID { get; set; }
        /// <summary>
        /// 是否关键字
        /// </summary>
        public bool IsInKeyword { get; set; } = false;
        /// <summary>
        /// 是否验重
        /// </summary>
        public bool Ischeckrepeat { get; set; } = false;
        /// <summary>
        /// 最大长度
        /// </summary>
        public int? MaxLen { get; set; }
        /// <summary>
        /// 最小长度
        /// </summary>
        public int? MinLen { get; set; }

        /// <summary>
        /// Input类型
        /// </summary>
        public string InputType { get; set; }

        /// <summary>
        /// 是否外键
        /// </summary>
        public bool IsForeign { get; set; } = false;

        /// <summary>
        /// 外键表
        /// </summary>
        public int ForeignTableID { get; set; }
       
        /// <summary>
        /// 外键值字段
        /// </summary>
        public int ForeignFiledID { get; set; }

        /// <summary>
        /// 外键表显示字段
        /// </summary>
        public int ForeignLableFiled { get; set; }
    }
}
